function datagrid(dataunit) {
	var data = {'thead':dataunit['thead'],'tbody':dataunit['tbody']};
	var htmlcode = '<table>';
	var thead = data['thead'];
	var html_thead = [];
	for(var i=0;i<thead.length;i++) {
		html_thead.push('<th>'+thead[i]+'</th>');
	}
	htmlcode += '<thead>'+html_thead.join('')+'</thead>';
	var tbody = data['tbody'];
	var html_tbody = [];
	for(var i=0;i<tbody.length;i++) {
		html_tbody.push('<tr>');
		for(var j=0;j<tbody[i].length;j++) {
			html_tbody.push('<td>'+tbody[i][j]+'</td>');
		}
		html_tbody.push('</tr>');
	}
	htmlcode += '<tbody>'+html_tbody.join('')+'</tbody>';
	htmlcode += '</table>';
	return htmlcode;
}